home *** CD-ROM | disk | FTP | other *** search
- Path: montana.avicom.net!not-for-mail
- From: zoot@montana.avicom.net (John Greenup)
- Newsgroups: comp.lang.c
- Subject: problem w/ realloc
- Date: 20 Mar 1996 19:21:20 -0700
- Organization: Avicom
- Distribution: usa
- Message-ID: <4iqef0$dqq@montana.avicom.net>
- NNTP-Posting-Host: montana.avicom.net
-
- I've been porting a piece of code from AIX 3.2.5 to linux 1.2.8
- (gcc 2.7.0) recently, and finaly chased down the last :-) bug. The code
- assumes that if you have a memory block, and you realloc it smaller, it
- doesn't move the block of memory, it just makes the "usable size" of it
- smaller. (in fact, my textbook ("advanced programming in the unix
- environment" stevens) supports this usage) unfortunately, xxgdb has
- revealed that the realloc is moving my pointer! am I mistaken about the
- standards, or is this a special case I'm not aware of?
- any help appreciated-
- john greenup
- Zoot Enterprises
- zoot@www.avicom.net
-
-